package cn.enilu.flash.bean.entity.transport;

import cn.enilu.flash.bean.entity.BaseEntity;
import cn.enilu.flash.bean.entity.shop.OrderItem;
import com.fasterxml.jackson.annotation.JsonManagedReference;
import lombok.Data;
import lombok.Getter;
import org.hibernate.annotations.Table;

import javax.persistence.*;
import java.util.List;

/**
 * 地图路线表
 */
@Data
@Table(appliesTo = "t_map_line",comment = "地图点信息")
@Entity(name="t_map_line")
public class MapLine extends BaseEntity {


    private Long groupId;


    @OneToMany(fetch = FetchType.EAGER,cascade = {CascadeType.ALL})
    @JoinColumn(name = "roadId",foreignKey = @ForeignKey(name = "none"))
    @JsonManagedReference
    private List<MapPoint> pointList;


}
